Optimal. Leaf size=47 \[ \frac{\sec ^3(c+d x)}{3 a^2 d}+\frac{\sec (c+d x)}{a^2 d}-\frac{\tanh ^{-1}(\cos (c+d x))}{a^2 d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.062176, antiderivative size = 47, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 4, integrand size = 22, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.182, Rules used = {3175, 2622, 302, 207} \[ \frac{\sec ^3(c+d x)}{3 a^2 d}+\frac{\sec (c+d x)}{a^2 d}-\frac{\tanh ^{-1}(\cos (c+d x))}{a^2 d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3175
Rule 2622
Rule 302
Rule 207
Rubi steps
\begin{align*} \int \frac{\csc (c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx &=\frac{\int \csc (c+d x) \sec ^4(c+d x) \, dx}{a^2}\\ &=\frac{\operatorname{Subst}\left (\int \frac{x^4}{-1+x^2} \, dx,x,\sec (c+d x)\right )}{a^2 d}\\ &=\frac{\operatorname{Subst}\left (\int \left (1+x^2+\frac{1}{-1+x^2}\right ) \, dx,x,\sec (c+d x)\right )}{a^2 d}\\ &=\frac{\sec (c+d x)}{a^2 d}+\frac{\sec ^3(c+d x)}{3 a^2 d}+\frac{\operatorname{Subst}\left (\int \frac{1}{-1+x^2} \, dx,x,\sec (c+d x)\right )}{a^2 d}\\ &=-\frac{\tanh ^{-1}(\cos (c+d x))}{a^2 d}+\frac{\sec (c+d x)}{a^2 d}+\frac{\sec ^3(c+d x)}{3 a^2 d}\\ \end{align*}
Mathematica [A] time = 0.0411074, size = 61, normalized size = 1.3 \[ \frac{\frac{\sec ^3(c+d x)}{3 d}+\frac{\sec (c+d x)}{d}+\frac{\log \left (\sin \left (\frac{1}{2} (c+d x)\right )\right )}{d}-\frac{\log \left (\cos \left (\frac{1}{2} (c+d x)\right )\right )}{d}}{a^2} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.065, size = 67, normalized size = 1.4 \begin{align*}{\frac{\ln \left ( -1+\cos \left ( dx+c \right ) \right ) }{2\,{a}^{2}d}}-{\frac{\ln \left ( 1+\cos \left ( dx+c \right ) \right ) }{2\,{a}^{2}d}}+{\frac{1}{3\,{a}^{2}d \left ( \cos \left ( dx+c \right ) \right ) ^{3}}}+{\frac{1}{{a}^{2}d\cos \left ( dx+c \right ) }} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 0.950793, size = 80, normalized size = 1.7 \begin{align*} -\frac{\frac{3 \, \log \left (\cos \left (d x + c\right ) + 1\right )}{a^{2}} - \frac{3 \, \log \left (\cos \left (d x + c\right ) - 1\right )}{a^{2}} - \frac{2 \,{\left (3 \, \cos \left (d x + c\right )^{2} + 1\right )}}{a^{2} \cos \left (d x + c\right )^{3}}}{6 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.69111, size = 198, normalized size = 4.21 \begin{align*} -\frac{3 \, \cos \left (d x + c\right )^{3} \log \left (\frac{1}{2} \, \cos \left (d x + c\right ) + \frac{1}{2}\right ) - 3 \, \cos \left (d x + c\right )^{3} \log \left (-\frac{1}{2} \, \cos \left (d x + c\right ) + \frac{1}{2}\right ) - 6 \, \cos \left (d x + c\right )^{2} - 2}{6 \, a^{2} d \cos \left (d x + c\right )^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} \frac{\int \frac{\csc{\left (c + d x \right )}}{\sin ^{4}{\left (c + d x \right )} - 2 \sin ^{2}{\left (c + d x \right )} + 1}\, dx}{a^{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.17125, size = 144, normalized size = 3.06 \begin{align*} \frac{\frac{3 \, \log \left (\frac{{\left | -\cos \left (d x + c\right ) + 1 \right |}}{{\left | \cos \left (d x + c\right ) + 1 \right |}}\right )}{a^{2}} + \frac{8 \,{\left (\frac{3 \,{\left (\cos \left (d x + c\right ) - 1\right )}}{\cos \left (d x + c\right ) + 1} + \frac{3 \,{\left (\cos \left (d x + c\right ) - 1\right )}^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + 2\right )}}{a^{2}{\left (\frac{\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} + 1\right )}^{3}}}{6 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]